<?php
/**
 * Created by PhpStorm.
 * User: baidu
 * Date: 17/7/27
 * Time: 下午5:57
 */
namespace app\common\model;
use think\Model;

class AdminUser extends Base {
//    protected $insert = ['password'=>'123456'];
    public function role(){
        return $this->belongsTo('Role')->bind('role_name');
    }
    public function getLastLoginTimeAttr($value){
        return date('Y-m-d H:i:s', $value);
    }
}